﻿#pragma once
#include <QObject>

class QModbusClient;
class QModbusDataUnit;

class ModbusEvent
{	
public:
	ModbusEvent() = default;
	virtual ~ModbusEvent() = default;
	virtual bool read(QModbusClient* client, int device) = 0;
	virtual bool update(QModbusClient* client, QModbusDataUnit const& dat, int device) = 0;
	virtual bool update(QModbusClient* client, int device) { return true; };
	virtual bool write(QModbusClient* client, QModbusDataUnit const& msg, int device) = 0;
};
